<!DOCTYPE html>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->
    <meta name="description" content="">
    <meta name="author" content="">
    <!-- <link rel="icon" href="../../favicon.ico"> -->

    <title>社保登录</title>

    <link href="/css/bootstrap.min.css" rel="stylesheet">
    <link href="/css/bootstrapValidator.min.css" rel="stylesheet">
    <!-- <link href="./css/login.css" rel="stylesheet"> -->
    <!-- <style>
               .panel-group{max-height:770px;overflow: auto;}
               .leftMenu{margin:10px;margin-top:5px;}
               .leftMenu .panel-heading{font-size:14px;padding-left:20px;height:36px;line-height:36px;color:white;position:relative;cursor:pointer;}/*转成手形图标*/
               .leftMenu .panel-heading span{position:absolute;right:10px;top:12px;}
               .leftMenu .menu-item-left{padding: 2px; background: transparent; border:1px solid transparent;border-radius: 6px;}
               .leftMenu .menu-item-left:hover{background:#C4E3F3;border:1px solid #1E90FF;}
           </style> -->
</head>

<body>

<div class="container">
    <h2 class="form-signin-heading">社保查询</h2>
    <div class="">
        <ul class="list-group sb-list">
            <#--<li class="list-group-item sb-city" tmp="HangZhou"><i class="icon-chevron-right"></i>杭州</li>-->
            <#--<li class="list-group-item sb-city" tmp="HangZhouXiaoShan"><i class="icon-chevron-right"></i>杭州萧山</li>-->
            <#--<li class="list-group-item sb-city" tmp="HangZhouYuHang"><i class="icon-chevron-right"></i>杭州余杭</li>-->
            <#--<li class="list-group-item sb-city" tmp="HangZhouTongLu"><i class="icon-chevron-right"></i>杭州桐庐</li>-->
            <#--<li class="list-group-item sb-city" tmp="HangZhouChunAn"><i class="icon-chevron-right"></i>杭州淳安</li>-->
            <#--<li class="list-group-item sb-city" tmp="HangZhouJianDe"><i class="icon-chevron-right"></i>杭州建德</li>-->
            <#--<li class="list-group-item sb-city" tmp="HangZhouFuYang"><i class="icon-chevron-right"></i>杭州富阳</li>-->
            <#--<li class="list-group-item sb-city" tmp="HangZhouLingAn"><i class="icon-chevron-right"></i>杭州临安</li>-->
        </ul>
    </div>
</div>
</body>
<script src="/js/jquery.min.js"></script>
<script src="/js/bootstrap.min.js"></script>
<script src="/js/bootstrapValidator.min.js"></script>
<script>
    //    var str = "{\"data\":[{\"text\":\"省本级\",\"value\":\"top\",\"children\":[{\"text\":\"省本级\",\"value\":\"top\"}]},{\"text\":\"杭州市\",\"value\":330100,\"children\":[{\"text\":\"市本级\",\"value\":330100},{\"text\":\"萧山区\",\"value\":330109},{\"text\":\"余杭区\",\"value\":330110},{\"text\":\"桐庐县\",\"value\":330122},{\"text\":\"淳安县\",\"value\":330127},{\"text\":\"建德市\",\"value\":330182},{\"text\":\"富阳区\",\"value\":330183},{\"text\":\"临安市\",\"value\":330185}]},{\"text\":\"宁波市\",\"value\":330201,\"children\":[{\"text\":\"市本级\",\"value\":330201},{\"text\":\"象山县\",\"value\":330225},{\"text\":\"宁海县\",\"value\":330226},{\"text\":\"慈溪市\",\"value\":330282}]},{\"text\":\"温州市\",\"value\":330301,\"children\":[{\"text\":\"市本级\",\"value\":330301},{\"text\":\"洞头县\",\"value\":330322},{\"text\":\"永嘉县\",\"value\":330324},{\"text\":\"平阳县\",\"value\":330326},{\"text\":\"苍南县\",\"value\":330327},{\"text\":\"文成县\",\"value\":330328},{\"text\":\"泰顺县\",\"value\":330329},{\"text\":\"瑞安市\",\"value\":330381},{\"text\":\"乐清市\",\"value\":330382}]},{\"text\":\"嘉兴市\",\"value\":330401,\"children\":[{\"text\":\"市本级\",\"value\":330401},{\"text\":\"嘉善县\",\"value\":330421},{\"text\":\"海盐县\",\"value\":330424},{\"text\":\"海宁市\",\"value\":330481},{\"text\":\"平湖市\",\"value\":330482},{\"text\":\"桐乡市\",\"value\":330483}]},{\"text\":\"湖州市\",\"value\":330501,\"children\":[{\"text\":\"市本级\",\"value\":330501},{\"text\":\"吴兴区\",\"value\":330502},{\"text\":\"南浔区\",\"value\":330503},{\"text\":\"德清县\",\"value\":330521},{\"text\":\"长兴县\",\"value\":330522},{\"text\":\"安吉县\",\"value\":330523}]},{\"text\":\"绍兴市\",\"value\":330601,\"children\":[{\"text\":\"市本级\",\"value\":330601},{\"text\":\"柯桥区\",\"value\":330621},{\"text\":\"新昌县\",\"value\":330624},{\"text\":\"诸暨市\",\"value\":330681},{\"text\":\"上虞市\",\"value\":330682},{\"text\":\"嵊州市\",\"value\":330683}]},{\"text\":\"金华市\",\"value\":330701,\"children\":[{\"text\":\"市本级\",\"value\":330701},{\"text\":\"武义县\",\"value\":330723},{\"text\":\"浦江县\",\"value\":330726},{\"text\":\"磐安县\",\"value\":330727},{\"text\":\"兰溪市\",\"value\":330781},{\"text\":\"义乌市\",\"value\":330782},{\"text\":\"东阳市\",\"value\":330783},{\"text\":\"永康市\",\"value\":330784}]},{\"text\":\"衢州市\",\"value\":330801,\"children\":[{\"text\":\"全市含市本级及所辖各县(市、区)\",\"value\":330801}]},{\"text\":\"舟山市\",\"value\":330901,\"children\":[{\"text\":\"全市含市本级及所辖各县(市、区)\",\"value\":330901}]},{\"text\":\"台州市\",\"value\":331001,\"children\":[{\"text\":\"市本级\",\"value\":331001},{\"text\":\"椒江区\",\"value\":331002},{\"text\":\"黄岩区\",\"value\":331003},{\"text\":\"路桥区\",\"value\":331004},{\"text\":\"玉环县\",\"value\":331021},{\"text\":\"三门县\",\"value\":331022},{\"text\":\"天台县\",\"value\":331023},{\"text\":\"仙居县\",\"value\":331024},{\"text\":\"温岭市\",\"value\":331081},{\"text\":\"临海市\",\"value\":331082}]},{\"text\":\"丽水市\",\"value\":331101,\"children\":[{\"text\":\"全市含市本级及所辖各县(市、区)\",\"value\":331101}]}]}";
    $.get("/sb/getSBPageInfoList",function(data){
        datas = data.data;
        var daStr = "";
        for (var key in datas) {
            if (datas.hasOwnProperty(key)) {
                var data = datas[key];
                console.log(data.key + "+++" + data.value);
                daStr += "<li class=\"list-group-item sb-city\" tmp=\"" + data.sbType + "\"><i class=\"icon-chevron-right\"></i> " + data.sbName + "</li>";
            }
        }
        $(".sb-list").append(daStr);
    })
//    var str = "{\"data\":[{\"key\":\"HangZhou\",\"value\":\"杭州\",\"status\":\"1\"},{\"key\":\"HangZhouXiaoShan\",\"value\":\"杭州萧山\",\"status\":\"1\"},{\"key\":\"HangZhouYuHang\",\"value\":\"杭州余杭\",\"status\":\"1\"},{\"key\":\"HangZhouTongLu\",\"value\":\"杭州桐庐\",\"status\":\"1\"},{\"key\":\"HangZhouChunAn\",\"value\":\"杭州淳安\",\"status\":\"1\"},{\"key\":\"HangZhouJianDe\",\"value\":\"杭州建德\",\"status\":\"1\"},{\"key\":\"HangZhouFuYang\",\"value\":\"杭州富阳\",\"status\":\"1\"},{\"key\":\"HangZhouLingAn\",\"value\":\"杭州临安\",\"status\":\"1\"}]}";
//    var daStr = "";
//    var json = JSON.parse(str)

    //校验
    $(function () {
        $('form').bootstrapValidator({
            message: 'This value is not valid',
            feedbackIcons: {
                valid: 'glyphicon glyphicon-ok',
                invalid: 'glyphicon glyphicon-remove',
                validating: 'glyphicon glyphicon-refresh'
            },
            fields: {
                username: {
                    message: '用户名验证失败',
                    validators: {
                        notEmpty: {
                            message: '用户名不能为空'
                        }
                    }
                },
                email: {
                    validators: {
                        notEmpty: {
                            message: '邮箱地址不能为空'
                        }
                    }
                }
            }
        });
    });
</script>
<script>
    $(function () {
        $(".panel-heading").click(function (e) {
            /*切换折叠指示图标*/
            $(this).find("span").toggleClass("glyphicon-chevron-down");
            $(this).find("span").toggleClass("glyphicon-chevron-up");
        });

        $(".sb-list").on("click", ".sb-city", function(){
            var tmp = $(this).attr("tmp");
            location.href = "/sb/index?sb=" + tmp;
        });
    });
</script>
</html>

